/**
 * My simple header template from child directory
 * Cell.java - ${projectName} - ${organizationName} - ${inceptionYear}
 */
package FourthTry;

/*
 * #%L
 * Ability-tester
 * %%
 * Copyright (C) 2014 AmazingSERKU
 * %%
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 * 
 *      http://www.apache.org/licenses/LICENSE-2.0
 * 
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 * #L%
 */


import FourthTry.properties.IProperty;

import java.util.ArrayList;

/**
 * Created with IntelliJ IDEA.
 * User: Gauss
 * Date: 05.01.14
 * Time: 16:05
 * To change this template use File | Settings | File Templates.
 */
public class Cell {

    private Coordinates coordinates;
    private boolean isAbroad = false;
    private boolean canMove = true;
    private ArrayList<IProperty> properties;

    public Cell(Coordinates coordinates) {
        this.coordinates = coordinates;
    }

    public boolean isAbroad() {
        return isAbroad;
    }

    public void setAbroad(boolean abroad) {
        isAbroad = abroad;
    }

    public ArrayList<IProperty> getProperties() {
        return properties;
    }

    public void setProperties(ArrayList<IProperty> properties) {
        this.properties = properties;
    }

    public void addProperty(IProperty property) {
        if (properties==null) {
            properties = new ArrayList<IProperty>();
        }
        properties.add(property);
    }

    public void setCoordinates(Coordinates coordinates) {
        this.coordinates = coordinates;
    }

    public Coordinates getCoordinates() {
        return coordinates;
    }

    public boolean isCanMove() {
        return canMove;
    }

    public void setCanMove(boolean canMove) {
        this.canMove = canMove;
    }
}
